<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>预定管理页面</title>
    <!-- bootstrap样式 -->
    <script src="../js/jquery-3.4.1.min.js"></script>
    <script src="../js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="../bootstrap/bootstrap.min.css">
    <link rel="stylesheet" href="../css/common.css">
    <script src="../js/common.js"> </script>
</head>
<body>

 
    <div class="container">
        <div id="wu-toolbar"><h2>楼层列表</h2>

            <div class="wu-toolbar-search">
                <label>楼层名称:</label><input id="search-name" class="wu-text" style="width:100px">
                
                <a href="#" id="search-btn" class="easyui-linkbutton" iconCls="icon-search">搜索</a>
            </div>
        </div>
        <table class="table table-bordered table-hover ">
            <thead>
                <tr>
                    <th>用户头像</th>
                    <th>用户姓名</th>
                    <th>密码</th>
                    <th>所属角色</th>
                    <th>性别</th>
                    <th>年龄</th>
                    <th>地址</th>
                    <th>操作</th>
                </tr>
            </thead>
            <tbody>
              <tr class="success">
                <td>2</td>
                <td>张三</td>
                <td>12123</td>
                <td>超级管理员</td>
                <td>男</td>
                <td>12</td>
                <td>大连</td>
                <td><button type="button" class="btn btn-link" data-toggle="modal" data-target="#edit-modal">编辑</button>
                  <a href="${pageContext.request.contextPath }/admin/ClsServlet/delcls?id=${cls.id }">删除</a>
                </td>
            </tr>
            <tr class="success">
              <td>3</td>
              <td>李四</td>
              <td>12123</td>
              <td>普通用户</td>
              <td>女</td>
              <td>18</td>
              <td>沈阳</td>
              <td><button type="button" class="btn btn-link" data-toggle="modal" data-target="#edit-modal">编辑</button>
                <a href="${pageContext.request.contextPath }/admin/ClsServlet/delcls?id=${cls.id }">删除</a>
              </td>
          </tr>
                
            </tbody>    
        </table>
         <!-- Button trigger modal -->
        <button type="button" class="btn btn-primary add-btn " data-toggle="modal" data-target="#add-modal">添加</button>

        
    </div>

  <!-- Modal 添加学生 -->
  <div class="modal fade" id="add-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
      <div class="modal-content">
        <div class="modal-header">
          <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
          <h4 class="modal-title" id="myModalLabel">添加学生信息</h4>
        </div>
        <div class="modal-body">
            <form class="form-horizontal" id="add-form" action="${pageContext.request.contextPath }/admin/StuServlet/addstus">

                <div class="form-group">
                  <label for="input-name" class="col-sm-2 control-label">姓名：</label>
                  <div class="col-sm-10">
                    <input type="text" class="form-control" name="name" id="input-name" placeholder="请输入学生姓名">
                  </div>
                </div>
                <div class="form-group">
                    <label for="input-age" class="col-sm-2 control-label">年龄：</label>
                    <div class="col-sm-10">
                      <input type="text" class="form-control" name="age" id="input-age" placeholder="请输入学生年龄">
                    </div>
                  </div>
                  <div class="form-group">
                    <label for="input-cls" class="col-sm-2 control-label">班级：</label>
                    <div class="col-sm-10">
                      <input type="text" class="form-control" name="cname" id="input-cls" placeholder="请输入学生班级">
                    </div>
                  </div>
 
              </form>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
          <button type="submit" class="btn btn-primary" form="add-form">保存</button>
        </div>
      </div>
    </div>
  </div>
<!-- Modal 编辑学生 -->
  <div class="modal fade" id="edit-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
      <div class="modal-content">
        <div class="modal-header">
          <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
          <h4 class="modal-title" id="myModalLabel">编辑学生信息</h4>
        </div>
        <div class="modal-body">
            <form class="form-horizontal" id="edit-form" action="edit">
                <div class="form-group">
                  <label for="input-id" class="col-sm-2 control-label">学号：</label>
                  <div class="col-sm-10">
                    <input type="text" class="form-control" id="input-id" value="101" disabled>
                  </div>
                </div>
                <div class="form-group">
                  <label for="input-name" class="col-sm-2 control-label">姓名：</label>
                  <div class="col-sm-10">
                    <input type="password" class="form-control" id="input-name" placeholder="请输入学生姓名">
                  </div>
                </div>
                <div class="form-group">
                    <label for="input-age" class="col-sm-2 control-label">年龄：</label>
                    <div class="col-sm-10">
                      <input type="password" class="form-control" id="input-age" placeholder="请输入学生年龄">
                    </div>
                  </div>
                  <div class="form-group">
                    <label for="input-cls" class="col-sm-2 control-label">班级：</label>
                    <div class="col-sm-10">
                      <input type="password" class="form-control" id="input-cls" placeholder="请输入学生班级">
                    </div>
                  </div>
 
              </form>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
          <button type="submit" class="btn btn-primary" form="edit-form">保存</button>
        </div>
      </div>
    </div>
  </div>

 
    
</body>
</html>